<?php

namespace App\Http\Controllers\Common;

use App\Http\Controllers\BaseController;
use App\Http\Validate\LianZhuo\LianZhuoValidate;
use App\Service\Common\LianZhuoService;
use Illuminate\Http\JsonResponse;
use Illuminate\Http\Request;
use Illuminate\Validation\ValidationException;
use Psr\Container\ContainerExceptionInterface;
use Psr\Container\NotFoundExceptionInterface;


class LzController extends BaseController
{
    /**
     * 支行信息
     *
     * @param Request $request
     * @return JsonResponse
     * @throws NotFoundExceptionInterface
     * @throws ValidationException|ContainerExceptionInterface
     */
    public function queryBankAps(Request $request): JsonResponse
    {
        $cardNo = $request->get("cardNo", "");
        LianZhuoValidate::queryBankApsValidate(["cardNo" => $cardNo]);
        return $this->success(LianZhuoService::queryBankAps($cardNo));
    }
}
